.. _`Filter rows in Table`: .. _`org.sysess.sympathy.filters.columnfilternode`: Filter rows in Table ```````````````````` .. image:: filter.svg :width: 48 Filter column using Tables. Documentation ::::::::::::: Filter the rows of `Value Table`, outputting a subset as `Filtered Table`. Filtering takes place by applying a conditional `Operator` for every row element in the `Value` column, to that element and the full `Reference` column: outputting any row where the condition is satisfied. These predefined operators can be used: - In Satisfied for any row in `Value Table` where the element from the `Value` column exists on any row of the `Reference` column. - Not in Satisfied for any row where `In` can be applied and is not satisfied. The `Operator` can also be defined as a lambda function in the configuration GUI. It will be called once for each element in the `Value` column with the full `Reference` column available under the name `ref`. The lambda function should return True or False. See https://docs.python.org/3/tutorial/controlflow.html#lambda-expressions for a description of lambda functions. Have a look at the :ref:`Table API` to see all the available methods and attributes. .. warning:: The labels of this node has changed. The columns Reference, Value used to be called C0, C1 respectively. This can be good to keep in mind if you are used to the old names. Definition :::::::::: Input ports ........... **port0** table Reference Table **port1** table Value Table Output ports ............ **port0** table Filtered Table Configuration ............. **Reference** (c0_column) Select reference column from the Reference Table. **Value** (c1_column) Select value column from the Value Table. **Operator** (filter_functions) Predefined conditional operator. **Custom filter** (predicate_function) Conditional operator defined as a lambda function **Use custom filter function** (use_custom_predicate) Use custom filter instead of predefined operator. Related nodes ............. * :ref:`org.sysess.sympathy.data.table.selecttablerows` * :ref:`org.sysess.sympathy.data.table.selecttablerowsfromtable` * :ref:`org.sysess.sympathy.slice.columns.table` Examples ........ * :download:`FilterRowsInTable.syx ` Implementation .............. .. automodule:: node_table_filter :noindex: .. class:: ColumnFilterNode :noindex: